package com.ktgj.customer.service.impl;

import java.util.List;

import com.ktgj.customer.domain.TravelContractDocument;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ktgj.customer.mapper.TravelContractDocumentMapper;
import com.ktgj.customer.service.ITravelContractDocumentService;

/**
 * 合同附件关联Service业务层处理
 * 
 * @author ruoyi
 * @date 2022-07-08
 */
@Service
public class TravelContractDocumentServiceImpl implements ITravelContractDocumentService 
{
    @Autowired
    private TravelContractDocumentMapper travelContractDocumentMapper;

    /**
     * 查询合同附件关联
     * 
     * @param travelContractDocumentId 合同附件关联ID
     * @return 合同附件关联
     */
    @Override
    public TravelContractDocument selectTravelContractDocumentById(Long travelContractDocumentId)
    {
        return travelContractDocumentMapper.selectTravelContractDocumentById(travelContractDocumentId);
    }

    /**
     * 查询合同附件关联列表
     * 
     * @param travelContractDocument 合同附件关联
     * @return 合同附件关联
     */
    @Override
    public List<TravelContractDocument> selectTravelContractDocumentList(TravelContractDocument travelContractDocument)
    {
        return travelContractDocumentMapper.selectTravelContractDocumentList(travelContractDocument);
    }

    /**
     * 新增合同附件关联
     * 
     * @param travelContractDocument 合同附件关联
     * @return 结果
     */
    @Override
    public int insertTravelContractDocument(TravelContractDocument travelContractDocument)
    {
        return travelContractDocumentMapper.insertTravelContractDocument(travelContractDocument);
    }

    /**
     * 修改合同附件关联
     * 
     * @param travelContractDocument 合同附件关联
     * @return 结果
     */
    @Override
    public int updateTravelContractDocument(TravelContractDocument travelContractDocument)
    {
        return travelContractDocumentMapper.updateTravelContractDocument(travelContractDocument);
    }

    /**
     * 批量删除合同附件关联
     * 
     * @param travelContractDocumentIds 需要删除的合同附件关联ID
     * @return 结果
     */
    @Override
    public int deleteTravelContractDocumentByIds(Long[] travelContractDocumentIds)
    {
        return travelContractDocumentMapper.deleteTravelContractDocumentByIds(travelContractDocumentIds);
    }

    /**
     * 删除合同附件关联信息
     * 
     * @param travelContractDocumentId 合同附件关联ID
     * @return 结果
     */
    @Override
    public int deleteTravelContractDocumentById(Long travelContractDocumentId)
    {
        return travelContractDocumentMapper.deleteTravelContractDocumentById(travelContractDocumentId);
    }
}
